

d = {'name': 'xiaoming', 'age': 18, 'height': 170}
# 字典查询
print(d['name'])
print(d.get('age '))
# 字典更新
d['name'] = 'daming'
d['weight'] = 130
d.update(age=19)
d.update({
    "age": 20,
    "color": 'blue'
})
# 字典的删除
del d['color']
d.pop('weight')
print(type(d), d)